/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package TweetRay.Backgrounds;

import processing.core.PApplet;
import processing.core.PVector;

/**
 *
 * @author Matt
 */
public class BackgroundFactory {


    public enum Backgrounds {
       GRADIENT, SOLID_WHITE, UFFUZI, CLEAR_SKY;
    }
    
    
    public static Background getBackGround(Backgrounds bg, PApplet parent){
        switch(bg){
            case SOLID_WHITE:
                return new SolidBackground(new PVector(.9f,.9f,.9f));
            case UFFUZI:
                return new ImageBackground(parent.loadImage("uffuzi.jpg"));
            case CLEAR_SKY:
                return new ClearSkyBackground();
            case GRADIENT:
                return new GradientBackground();
        }
        
        //should never get here
      return new SolidBackground(new PVector(.5f,.5f,.6f));
    }
    
    
}
